There are automatic lathes in use that fabricate a plurality of workpieces from a bar by cutting the bar while moving the bar in the longitudinal direction. In general, it is difficult for an automatic lathe to cut a bar to its end, and a remaining material is generated after the cutting. The remaining material cannot be subjected to cutting by the automatic lathe and it is discarded.
For this reason, the automatic lathe disclosed in Patent Literature 1 includes a detection unit that detects the length of a remaining bar. When workpieces having different lengths are fabricated, the automatic lathe disclosed in Patent Literature 1 selects a workpiece to be fabricated depending on the detection result of the detection unit, i.e., the length of a remaining material, to shorten the remaining material.